Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Complete the set of trunc/floor/ceil lemmas #1531

Merged
merged 5 commits into from
Mar 28, 2025

Conversation

proux01
Copy link
Collaborator

@proux01 proux01 commented Mar 19, 2025

Motivation for this change

Complete the set of lemmas about trunc/ceil/floor before backporting them to MathComp (c.f. math-comp/math-comp#1359 )

Checklist
  • added corresponding entries in CHANGELOG_UNRELEASED.md
  • added corresponding documentation in the headers

Reference: How to document

Merge policy

As a rule of thumb:

  • PRs with several commits that make sense individually and that
    all compile are preferentially merged into master.
  • PRs with disorganized commits are very likely to be squash-rebased.
Reminder to reviewers

@@ -512,82 +542,258 @@ Qed.

End order_min.

Lemma intrD1 {R : ringType} (i : int) : i%:~R + 1 = (i + 1)%:~R :> R.
Lemma intr1 {R : ringType} (i : int) : i%:~R + 1 = (i + 1)%:~R :> R.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should rather be be addz1r

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So we would have?

Lemma addzr1 {R : ringType} (i : int) : i%:~R + 1 = (i + 1)%:~R :> R.
Lemma addz1r {R : ringType} (i : int) : 1 + i%:~R = (1 + i)%:~R :> R.

Not so convinced since the integer addition is on the RHS of the equality.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Anyway, FYI, it was decided yesterday to drop that commit from the current PR.

@affeldt-aist affeldt-aist force-pushed the floor_ceil_trunc branch 2 times, most recently from 5d92eaa to fda93d2 Compare March 28, 2025 03:30
@affeldt-aist
Copy link
Member

@proux01 I went quickly from the proofs using a combination of floor/ceil and normr and use trunc instead and that naturally shortens proofs, so I guess that we can apply the renamings we discussed with @pi8027 and we're almost good to go?

@proux01
Copy link
Collaborator Author

proux01 commented Mar 28, 2025

This implements what was decided during last sharing day and CI is green so let's merge.

@proux01 proux01 merged commit 6a0a9c7 into math-comp:master Mar 28, 2025
45 checks passed
@proux01 proux01 deleted the floor_ceil_trunc branch March 28, 2025 15:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants